package com.bat.listener;

import lombok.extern.slf4j.Slf4j;
import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
import org.apache.rocketmq.spring.core.RocketMQListener;
import org.springframework.stereotype.Service;

/**
 * @Description:
 * @Author: zpf
 * @Date: 2019/12/7 下午4:47
 */
@Service
@RocketMQMessageListener(topic = "topic", consumerGroup = "topic-zpf-consumer1", enableMsgTrace = true,
    customizedTraceTopic = "my-trace-topic")
@Slf4j
public class RocketMqListener implements RocketMQListener<String> {
    @Override
    public void onMessage(String s) {
        log.info("接收的消息NOACK{}", s);
    }

}
